package example.book.model;

import lombok.Data;

@Data
public class PageRequest {
    private int currentPage = 1;//当前页
    private int pageSize = 10;//总页数
    private int offset;
    //计算索引
    public int getOffset() {
        return (currentPage-1) * pageSize;
    }
}
